<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<script src="./node_modules/vue/dist/vue.js"></script>
<body>
<div id="app">
    <counter></counter>
    <counter></counter>
</div>
<script>

    Vue.component("counter",{
        template:'<button v-on:click="count++">你点了我 {{ count }} 次，我记住了.</button>',
        data(){
            return {
                count:1
            }
        }
    });

    const app = new Vue({
        el:"#app",
    });
</script>
</body>
</html>